<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .flex-container {
            display: flex;
            flex-flow: row wrap;
            /* 设置主轴为水平和允许换行 */
            justify-content: flex-start;
            padding: 10px;
            width: 800px;
            border: 1px solid #000;
        }

        .flex-item {
            flex: 0 0 100px;
            /* 不允许弹性伸缩，固定宽度为 100px */
            height: 50px;
            margin: 5px;
            background-color: #999;
            color: #fff;
            text-align: center;
            line-height: 50px;
            border: 1px solid #666;
        }
    </style>
</head>

<body>
    <p>flex-flow属性是flex-direction属性和flex-wrap属性的简写形式。</p>
    <p>flex-flow 的值是由两部分组成的，第一部分是 flex-direction，第二部分是 flex-wrap。默认值为row nowrap。</p>
    <div class="flex-container">
        <div class="flex-item">1</div>
        <div class="flex-item">2</div>
        <div class="flex-item">3</div>
        <div class="flex-item">4</div>
        <div class="flex-item">5</div>
        <div class="flex-item">6</div>
        <div class="flex-item">7</div>
        <div class="flex-item">8</div>
        <div class="flex-item">9</div>
        <div class="flex-item">10</div>
    </div>
</body>

</html>